package com.hitrust.gs.action;

import java.util.ArrayList;
import system.LoginContext;
import com.hitrust.gs.business.GSUniteGwProcessor;
import com.hitrust.gs.lib.GSBaseConstants;
import com.hitrust.gs.service.GSBaseAction;
import com.hitrust.gs.service.GSBaseForm;

/**
 * @author simonyi
 *
 * TODO To change the template for this generated type comment go to
 * Window - Preferences - Java - Code Style - Code Templates
 */
public class GSOrderFirstAuditInitAction extends GSBaseAction {
	public String execute(GSBaseForm aForm) throws Exception {
	    aForm.getSession().removeAttribute("QUERYCONDITION");
        //查询当前操作员所能操作的订货单位和地址
        LoginContext loginContext = (LoginContext)aForm.getSession().getAttribute(GSBaseConstants.LOGIN);
        GSUniteGwProcessor processer = new GSUniteGwProcessor();
        ArrayList ary = processer.getWareHouseLevelName(loginContext.getLoginWarehouseCode(),loginContext.getLoginWarehouseCode());
        aForm.getRequest().setAttribute("organdaddr",ary);
        return GSBaseConstants.FORWARD_SUCCESS;
	}
}
